import axios from "./axios";
import { base } from '@/conf'

// 比赛
export const getCptt = params => axios.get('/cptt/select',{params})
.then(e=>{
  console.log({e})
  e.cptts.map(item=>{
    if(item.imgname) item.url = base.imgUrl + item.imgname
    delete item.imgname
  })
  console.log({e})
  return e
})

export const getEvent = params => axios.get('/cptt/event',{params})

export const getApplay = params => axios.get('/cptt/getapplay',{params})
//报名
export const applayCptt = data => axios.post('/cptt/applaycptt',data)
//我的小队的人
export const getmygroup = params => axios.get('/cptt/getmygroup',{params})

export const getIsApplay = params => axios.get('/cptt/getisapplay',{params})
